function showArticle(id) {
	var loading = weui.loading('加载中');

	$.ajax({
		url: '/api/shop/getArticle',
		method: 'post',
		data: {
			id: id
		},
		success: function(res) {
			$('.popup_article .popup_box_top span').html(res.data.title);
			$('.popup_article .popup_box_content').html(res.data.content);
		}
	})

	$('.popup_mask').show();
	$('.popup_article').slideDown();
	loading.hide();
}

function showPutScrip(sex) {
	$('input[name="sex"]').val(sex);
  $('.popup_mask').show();
  $('.popup_put_scrip').slideDown();
}

function showTakeScrip(sex) {
	if (sex == 'man') {
		$('.popup_take_scrip .popup_box_top span').html('抽取1张男生纸条');
		$('.popup_take_scrip .sex_box').removeClass('woman_box').addClass('man_box');
		$('.popup_take_scrip .sex_box img').attr('src', '/static/web/images/man_box.png');
	}
	if (sex == 'woman') {
		$('.popup_take_scrip .popup_box_top span').html('抽取1张女生纸条');
		$('.popup_take_scrip .sex_box').removeClass('man_box').addClass('woman_box');
		$('.popup_take_scrip .sex_box img').attr('src', '/static/web/images/woman_box.png');
	}
	$('#take_scrip_sex').val(sex);
	$('.popup_mask').show();
  $('.popup_take_scrip').slideDown();
}

function showGold() {
	$('.popup_mask').show();
	$('.popup_gold').slideDown();
}

function closeMask() {
	$('.popup_mask').hide();
	$('.popup_box').slideUp();
}